@extends('new.layouts.indexPublic')
@section('title',Site::get('hometitle'))
{{--首页css--}}
@section('headcss')
    <meta name="keywords" content="{{Site::get('homekeywords')}}">
    <meta name="description" content="{{Site::get('homedescription')}}">
    @parent
    <link rel="stylesheet" href="{{asset('/new/css/index/index.css')}}">
    <link rel="stylesheet" href="{{asset('/vendor/swiper/skin/swiper2.7.6.css')}}">
@endsection

{{--主体内容--}}
@section('content')
    {{--logo、搜索栏--}}
    @include('new.layouts.logoAndSearch')
    {{--logo、搜索栏结束--}}

    {{--主导航--}}
    @include('new.layouts.mainNav')
    {{--主导航结束--}}

    {{--主要内容--}}
    <div class="main">
        <div class="wrapper">
            {{--顶部登录框以及广告图--}}
            <div class="mainTop">
                {{--个人、企业登录--}}
                <div class="login">
                    {{--判断有没有登录前台--}}
                    @if(auth()->guard('personal')->check())
                        <div class="loggedIn">
                            <p>欢迎您，<span class="username">{{ str_limit((auth()->guard('personal')->user()->username?:auth()->guard('personal')->user()->mobile),8)}}</span></p>
                            <span class="logout"><a href="{{url('personal/logout')}}">退出</a></span>
                        </div>
                        <div class="loggedInfo">
                            <a href="{{url('personal/resume_mange')}}"><i class="pos resumeManage"></i><span>简历管理</span></a>
                            <a class="noBorderRight" href="{{url('personal/resume_refresh')}}"><i class="refresh"></i><span>刷新简历</span></a>
                            <a href="{{url('personal/interview')}}"><strong>{{$interview_count}}</strong><span>面试邀请</span></a>
                            <a class="noBorderRight" href="{{url('personal/browse_resume')}}"><strong>{{$browse_resume_count}}</strong><span>谁看过我</span></a>
                        </div>
                        <div class="accountCenter"><a href="{{url('personal/welcome')}}">账户中心</a></div>
                    @elseif(auth()->guard('company')->check())
                        <div class="loggedIn">
                            <p>欢迎您，<span class="username">{{msubstr(auth()->guard('company')->user()->username,0,8)}}</span></p>
                            <span class="logout"><a href="{{url('company/logout')}}">退出</a></span>
                        </div>
                        <div class="loggedInfo">
                            <a href="{{url('company/jobadmin')}}"><i class="pos"></i><span>职位管理</span></a>
                            <a class="noBorderRight" href="{{url('company/welcome?refreshtip=yes')}}"><i class="refresh"></i><span>刷新职位</span></a>
                            <a href="{{url('company/jobpublish')}}"><strong>{{$companyJobCount}}</strong><span>发布职位</span></a>
                            <a class="noBorderRight" href="{{url('company/resume_message')}}"><strong>{{$resumeSendCount}}</strong><span>查收简历</span></a>
                        </div>
                        <div class="accountCenter"><a href="{{url('company/welcome')}}">账户中心</a></div>
                    @else
                        <div class="loginSwitch">
                            <a class="active" href="javascript:void(0)" data-a-text="personal">个人登录</a>
                            <a href="javascript:void(0)" data-a-text="company">企业登录</a>
                        </div>
                        {{--个人登录--}}
                        <form class="personal" action="{{url('personal/welcome')}}" onsubmit="return checkPersonal('#personalForm')" method="post" id="personalForm"  name="personalForm">
                            {!! csrf_field() !!}
                            <input type="text" name="username" id="username" value="" placeholder="个人用户名" autocomplete="off">
                            <input type="password" name="password" id="password"  value="" placeholder="密码" autocomplete="off">
                            <div class="box">
                                <input class="autoLogin" id="autoLogin" type="checkbox" name="remember"><label for="autoLogin">自动登录</label>
                                <a href="{{url('personal/find_password')}}">忘记密码？</a>
                            </div>
                            <div class="box2">
                                <button type="submit">登录</button>
                                @if(!empty(Site::get('personAppid')))
                                    <a class="qq" href="{{ url("personal/qqlogin") }}"></a>
                                    {{--<a class="wx" href="{{ weiXinlogin('personal') }}"></a>--}}
                                @endif
                            </div>
                            <div class="register">
                                <a href="{{url('personal/register')}}">个人注册</a><a href="{{url('company/register')}}">企业注册</a>
                            </div>
                        </form>
                        {{--企业登录--}}
                        <form class="company hide" action="{{url('company/welcome')}}" method="post" onsubmit="return checkCompany('#companyForm')" id="companyForm"  name="companyForm">
                            {!! csrf_field() !!}
                            <input type="text" name="username" id="username" placeholder="企业用户名" autocomplete="off">
                            <input type="password" name="password" id="password" placeholder="密码" autocomplete="off">
                            <div class="box">
                                <input class="autoLogin" id="autoLogin" type="checkbox" name="remember">
                                <label for="autoLogin">自动登录</label>
                                <a href="{{url('company/find_password')}}">忘记密码？</a>
                            </div>
                            <div class="box2">
                                <button type="submit">登录</button>
                                @if(!empty(Site::get('CompanyAppid')))
                                    <a class="qq" href="{{ url("company/qqlogin") }}"></a>
                                    {{--<a class="wx" href="{{ weiXinlogin('company') }}"></a>--}}
                                @endif
                            </div>
                            <div class="register">
                                <a href="{{url('personal/register')}}">个人注册</a><a href="{{url('company/register')}}">企业注册</a>
                            </div>
                        </form>
                    @endif
                </div>
                {{--个人、企业登录结束--}}

                {{--轮播图以及广告--}}
                <div class="banner">
                    {{--轮播图--}}
                    <div class="swiper-container">
                        @if(count($loginT1) > 0)
                            <ul class="swiper-wrapper">
                                @foreach($loginT1 as $v)
                                    <li class="swiper-slide swiper-no-swiping">
                                        <a  href="{{$v->ad_url}}" target="_blank"><img src="{{$v->pic_url}}" alt="{{$v->title}}"></a>
                                    </li>
                                @endforeach
                            </ul>
                            <div class="play-mid-btn play-mid-BL"></div>
                            <div class="play-mid-btn play-mid-BR"></div>
                        @else
                            <ul class="swiper-wrapper noBanner">
                                <li class="swiper-slide swiper-no-swiping">您还没有添加广告图！</li>
                            </ul>
                        @endif
                    </div>
                    {{--轮播图结束--}}
                    {{--广告图--}}
                    <div class="brand">
                        @if(count($loginT2) > 0)
                            @foreach($loginT2 as $v)
                                <a href="{{$v->ad_url}}" target="_blank">
                                    <img src="{{$v->pic_url}}" alt="{{$v->title}}" width="223" height="104">
                                    <div class="brand_info">
                                        <p>{{$v->title}}</p>
                                        <i class="hLine"></i>
                                        <span class="title">急聘：</span>
                                        <span>{{$v->job_title}}</span>
                                    </div>
                                </a>
                            {{--@foreach($mingP as $k=>$v)--}}
                                {{--@if($k < 3)--}}
                                    {{--<a href="{{$v->ad_url}}" target="_blank"><img src="{{$v->pic_url}}" alt="" width="223" height="104"></a>--}}
                                {{--@endif--}}
                            @endforeach
                        @else
                            <span class="noBrand">您还没有添加广告图！</span>
                        @endif
                    </div>
                </div>
            </div>
            {{--顶部登录框以及广告图结束--}}

            {{--今日高薪--}}
            <div class="todayJobs">
                <h2>
                    <span>今日高薪</span>
                    {{--<a href="javascript:void(0)">更多</a>--}}
                </h2>
                @if(count($jobList) > 0)
                    <ul>
                        @foreach($jobList as $k=>$v )
                            <li @if($k % 2 != 0) class="noMarginRight" @endif>
                                <p class="p1">
                                    <a class="title" href="{{$v->joburl}}" target="_blank">{{$v->job_title}}</a>
                                    {{--<span>2017-12-12</span>--}}
                                </p>
                                <p class="p2">
                                   <span class="salary">{{$v->money}}</span>
                                   <span class="address">椒江</span>
                                </p>
                                <p class="p3"><a href="{{$v->comurl}}" target="_blank">{{$v->company_name}}</a></p>
                            </li>
                        @endforeach
                    </ul>
                @else
                    <span class="noJobs">您还没有添加高薪职位...</span>
                @endif
            </div>
            {{--今日高薪结束--}}

            {{--中间长短广告条--}}
            <div class="centerAdv">
                @if(count($half) > 0)
                    <ul class="advHalf">
                        @foreach($half as $k=>$v)
                            <li @if($k % 2 != 0)class="noMarginRight"@endif>
                                <a  href="{{$v->ad_url}}"  target="_blank">
                                    <img src="{{$v->pic_url}}" alt="{{$v->title}}" width="490" height="80">
                                </a>
                            </li>
                        @endforeach
                    </ul>
                @endif
                @if(count($short) > 0)
                    <ul class="advShort">
                        @foreach($short as $v)
                            <li>
                                <a  href="{{$v->ad_url}}" target="_blank">
                                    <img src="{{$v->pic_url}}" alt="{{$v->title}}" width="150" height="80">
                                </a>
                            </li>
                        @endforeach
                    </ul>
                @endif
                {{--暂时没有长条广告图的相关数据--}}
                {{--<ul class="advLong hide">--}}
                    {{--<li>--}}
                        {{--<a href="javascript:void(0)" target="_blank">--}}
                            {{--<img src="" alt="" width="1000" height="80">--}}
                        {{--</a>--}}
                    {{--</li>--}}
                    {{--<li>--}}
                        {{--<a href="javascript:void(0)" target="_blank">--}}
                            {{--<img src="" alt="" width="1000" height="80">--}}
                        {{--</a>--}}
                    {{--</li>--}}
                {{--</ul>--}}
            </div>
            {{--中间长短广告条结束--}}

            {{--职位分类以及推荐职位--}}
            <div class="jobClasses">
                {{--销售/营销/贸易/外贸--}}
                <div class="box">
                    <div class="classes sales">
                        <dl>
                            <dt>销售/营销/贸易/外贸</dt>
                            <dd><a href="{{url('/job?jobsort1=110101')}}" target="_blank">销售代表</a></dd>
                            <dd><a href="{{url('/job?jobsort1=110102')}}" target="_blank">电话销售</a></dd>
                            <dd><a href="{{url('/job?jobsort1=110103')}}" target="_blank">客户经理</a></dd>
                            <dd><a href="{{url('/job?jobsort1=110104')}}" target="_blank">营业员</a></dd>
                            <dd><a href="{{url('/job?jobsort1=110106')}}" target="_blank">医药代表</a></dd>
                            <dd><a href="{{url('/job?jobsort1=110107')}}" target="_blank">分销专员</a></dd>
                            <dd><a href="{{url('/job?jobsort1=110108')}}" target="_blank">团购业务员</a></dd>
                            <dd><a href="{{url('/job?jobsort1=110109')}}" target="_blank">招商专员</a></dd>
                            <dd><a href="{{url('/job?jobsort1=110202')}}" target="_blank">销售经理</a></dd>
                            <dd><a href="{{url('/job?jobsort1=110203')}}" target="_blank">渠道分销</a></dd>
                            <dd><a href="{{url('/job?jobsort1=110204')}}" target="_blank">团购经理</a></dd>
                            <dd><a href="{{url('/job?jobsort1=110302')}}" target="_blank">客服经理</a></dd>
                            <dd><a href="{{url('/job?jobsort1=110303')}}" target="_blank">客服专员</a></dd>
                            <dd><a href="{{url('/job?jobsort1=110403')}}" target="_blank">营销专员</a></dd>
                            <dd><a href="{{url('/job?jobsort1=110408')}}" target="_blank">促销员/督导</a></dd>
                            <dd><a href="{{url('/job?jobsort1=110503')}}" target="_blank">品牌经营</a></dd>
                            <dd><a href="{{url('/job?jobsort1=110505')}}" target="_blank">会务安排</a></dd>
                        </dl>
                    </div>
                    <div class="jobLists">
                        <ul>
                            @if(count($sellCate) > 0)
                                <?php $i = 0;?>
                                @foreach($sellCate as $v)
                                    @if($i < 8)
                                        <li>
                                            <p class="p1">
                                                <a href="{{$v->joburl}}" target="_blank">{{$v->job_title}}</a>
                                                @if($v->urgent==1)<i class="one status"></i>@endif
                                                <span>{{$v->money}}</span>
                                            </p>
                                            <p class="p2">
                                                <span>{{$v->location1}}</span>
                                                <a href="{{$v->comurl}}"  target="_blank">{{$v->company_name}}</a>
                                            </p>
                                        </li>
                                    @endif
                                    <?php $i++;?>
                                @endforeach
                            @else
                                <li class="noJob">您还没有添加这个类别急招职位!</li>
                            @endif
                        </ul>
                    </div>
                </div>
                {{--文职/行政/客服类--}}
                <div class="box">
                    <div class="classes clerical">
                        <dl>
                            <dt>文职/行政/客服类</dt>
                            <dd><a href="{{url('/job?jobsort1=120101')}}" target="_blank">人力资源专员</a></dd>
                            <dd><a href="{{url('/job?jobsort1=120102')}}" target="_blank">招聘专员</a></dd>
                            <dd><a href="{{url('/job?jobsort1=120103')}}" target="_blank">培训专员</a></dd>
                            <dd><a href="{{url('/job?jobsort1=120107')}}" target="_blank">人力资源经理</a></dd>
                            <dd><a href="{{url('/job?jobsort1=120206')}}" target="_blank">保安</a></dd>
                            <dd><a href="{{url('/job?jobsort1=120201')}}" target="_blank">行政专员</a></dd>
                            <dd><a href="{{url('/job?jobsort1=120202')}}" target="_blank">文员</a></dd>
                            <dd><a href="{{url('/job?jobsort1=120203')}}" target="_blank">前台接待</a></dd>
                            <dd><a href="{{url('/job?jobsort1=120204')}}" target="_blank">高管助理</a></dd>
                            <dd><a href="{{url('/job?jobsort1=120212')}}" target="_blank">行政经理</a></dd>
                            <dd><a href="{{url('/job?jobsort1=120301')}}" target="_blank">财务专员</a></dd>
                            <dd><a href="{{url('/job?jobsort1=120302')}}" target="_blank">会计</a></dd>
                            <dd><a href="{{url('/job?jobsort1=120303')}}" target="_blank">出纳</a></dd>
                            <dd><a href="{{url('/job?jobsort1=120304')}}" target="_blank">投融资</a></dd>
                            <dd><a href="{{url('/job?jobsort1=120305')}}" target="_blank">审计专员</a></dd>
                            <dd><a href="{{url('/job?jobsort1=120309')}}" target="_blank">结算专员</a></dd>
                            <dd><a href="{{url('/job?jobsort1=120501')}}" target="_blank">高级管理CEO</a></dd>
                        </dl>
                    </div>
                    <div class="jobLists">
                        <ul>
                            @if(count($civilianCate) > 0)
                                <?php $i = 0;?>
                                @foreach($civilianCate as $v)
                                    @if($i < 8)
                                        <li>
                                            <p class="p1">
                                                <a href="{{$v->joburl}}" target="_blank">{{$v->job_title}}</a>
                                                @if($v->urgent==1)<i class="one status"></i>@endif
                                                <span>{{$v->money}}</span>
                                            </p>
                                            <p class="p2">
                                                <span>{{$v->location1}}</span>
                                                <a href="{{$v->comurl}}"  target="_blank">{{$v->company_name}}</a>
                                            </p>
                                        </li>
                                    @endif
                                    <?php $i++;?>
                                @endforeach
                            @else
                                <li class="noJob">您还没有添加这个类别急招职位!</li>
                            @endif
                        </ul>
                    </div>
                </div>
                {{--餐饮/百货/生活服务--}}
                <div class="box">
                    <div class="classes dining">
                        <dl>
                            <dt>餐饮/百货/生活服务</dt>
                            <dd><a href="{{url('/job?jobsort1=200104')}}" target="_blank">厨师</a></dd>
                            <dd><a href="{{url('/job?jobsort1=200107')}}" target="_blank">送餐员</a></dd>
                            <dd><a href="{{url('/job?jobsort1=200110')}}" target="_blank">服务员</a></dd>
                            <dd><a href="{{url('/job?jobsort1=200113')}}" target="_blank">吧员</a></dd>
                            <dd><a href="{{url('/job?jobsort1=200116')}}" target="_blank">洗碗工</a></dd>
                            <dd><a href="{{url('/job?jobsort1=200201')}}" target="_blank">酒店管理</a></dd>
                            <dd><a href="{{url('/job?jobsort1=200202')}}" target="_blank">大堂经理</a></dd>
                            <dd><a href="{{url('/job?jobsort1=200204')}}" target="_blank">前台接待</a></dd>
                            <dd><a href="{{url('/job?jobsort1=200205')}}" target="_blank">预定员</a></dd>
                            <dd><a href="{{url('/job?jobsort1=200208')}}" target="_blank">保安</a></dd>
                            <dd><a href="{{url('/job?jobsort1=200209')}}" target="_blank">保洁员</a></dd>
                            <dd><a href="{{url('/job?jobsort1=200403')}}" target="_blank">搬运工</a></dd>
                            <dd><a href="{{url('/job?jobsort1=200404')}}" target="_blank">保洁员</a></dd>
                            <dd><a href="{{url('/job?jobsort1=200308')}}" target="_blank">健身教练</a></dd>
                            <dd><a href="{{url('/job?jobsort1=200310')}}" target="_blank">瑜伽老师</a></dd>
                            <dd><a href="{{url('/job?jobsort1=200504')}}" target="_blank">营业员</a></dd>
                            <dd><a href="{{url('/job?jobsort1=200505')}}" target="_blank">导购员</a></dd>
                            <dd><a href="{{url('/job?jobsort1=200507')}}" target="_blank">收银员</a></dd>
                            <dd><a href="{{url('/job?jobsort1=200508')}}" target="_blank">理货员</a></dd>
                            <dd><a href="{{url('/job?jobsort1=200512')}}" target="_blank">其他（百货/零售）</a></dd>
                        </dl>
                    </div>
                    <div class="jobLists">
                        <ul>
                            @if(count($foodCate) > 0)
                                <?php $i = 0;?>
                                @foreach($foodCate as $v)
                                    @if($i < 8)
                                        <li>
                                            <p class="p1">
                                                <a href="{{$v->joburl}}" target="_blank">{{$v->job_title}}</a>
                                                @if($v->urgent==1)<i class="one status"></i>@endif
                                                <span>{{$v->money}}</span>
                                            </p>
                                            <p class="p2">
                                                <span>{{$v->location1}}</span>
                                                <a href="{{$v->comurl}}"  target="_blank">{{$v->company_name}}</a>
                                            </p>
                                        </li>
                                    @endif
                                    <?php $i++;?>
                                @endforeach
                            @else
                                <li class="noJob">您还没有添加这个类别急招职位!</li>
                            @endif
                        </ul>
                    </div>
                </div>
                {{--广告/设计/传媒--}}
                <div class="box">
                    <div class="classes adv">
                        <dl>
                            <dt>广告/设计/传媒</dt>
                            <dd><a href="{{url('/job?jobsort1=190103')}}" target="_blank">广告客户专员</a></dd>
                            <dd><a href="{{url('/job?jobsort1=190105')}}" target="_blank">广告创意/设计</a></dd>
                            <dd><a href="{{url('/job?jobsort1=190107')}}" target="_blank">文案策划</a></dd>
                            <dd><a href="{{url('/job?jobsort1=190109')}}" target="_blank">会务/会展</a></dd>
                            <dd><a href="{{url('/job?jobsort1=190201')}}" target="_blank">平面设计师</a></dd>
                            <dd><a href="{{url('/job?jobsort1=190203')}}" target="_blank">网页设计</a></dd>
                            <dd><a href="{{url('/job?jobsort1=190207')}}" target="_blank">家具设计</a></dd>
                            <dd><a href="{{url('/job?jobsort1=190211')}}" target="_blank">建筑设计</a></dd>
                            <dd><a href="{{url('/job?jobsort1=190213')}}" target="_blank">工业设计</a></dd>
                            <dd><a href="{{url('/job?jobsort1=190216')}}" target="_blank">设计总监</a></dd>
                            <dd><a href="{{url('/job?jobsort1=190301')}}" target="_blank">编导/导演</a></dd>
                            <dd><a href="{{url('/job?jobsort1=190302')}}" target="_blank">主持人</a></dd>
                            <dd><a href="{{url('/job?jobsort1=190303')}}" target="_blank">演员/模特</a></dd>
                            <dd><a href="{{url('/job?jobsort1=190307')}}" target="_blank">后期制作</a></dd>
                            <dd><a href="{{url('/job?jobsort1=190308')}}" target="_blank">经纪人</a></dd>
                            <dd><a href="{{url('/job?jobsort1=190401')}}" target="_blank">编辑</a></dd>
                            <dd><a href="{{url('/job?jobsort1=190405')}}" target="_blank">排版设计</a></dd>
                            <dd><a href="{{url('/job?jobsort1=190406')}}" target="_blank">制版/印刷操作</a></dd>
                        </dl>
                    </div>
                    <div class="jobLists">
                        <ul>
                            @if(count($advertisingCate) > 0)
                                <?php $i = 0;?>
                                @foreach($advertisingCate as $v)
                                    @if($i < 8)
                                        <li>
                                            <p class="p1">
                                                <a href="{{$v->joburl}}" target="_blank">{{$v->job_title}}</a>
                                                @if($v->urgent==1)<i class="one status"></i>@endif
                                                <span>{{$v->money}}</span>
                                            </p>
                                            <p class="p2">
                                                <span>{{$v->location1}}</span>
                                                <a href="{{$v->comurl}}"  target="_blank">{{$v->company_name}}</a>
                                            </p>
                                        </li>
                                    @endif
                                    <?php $i++;?>
                                @endforeach
                            @else
                                <li class="noJob">您还没有添加这个类别急招职位!</li>
                            @endif
                        </ul>
                    </div>
                </div>
                {{--能源/化工/服装--}}
                <div class="box">
                    <div class="classes energy">
                        <dl>
                            <dt>能源/化工/服装</dt>
                            <dd><a href="{{url('/job?jobsort1=230103')}}" target="_blank">水利/水电工程师</a></dd>
                            <dd><a href="{{url('/job?jobsort1=230104')}}" target="_blank">制冷/暖通工程师</a></dd>
                            <dd><a href="{{url('/job?jobsort1=230106')}}" target="_blank">新能源工程师</a></dd>
                            <dd><a href="{{url('/job?jobsort1=230201')}}" target="_blank">化工工程师</a></dd>
                            <dd><a href="{{url('/job?jobsort1=230203')}}" target="_blank">涂料研发工程师</a></dd>
                            <dd><a href="{{url('/job?jobsort1=230204')}}" target="_blank">食品/饮料研发</a></dd>
                            <dd><a href="{{url('/job?jobsort1=230205')}}" target="_blank">安全工程师</a></dd>
                            <dd><a href="{{url('/job?jobsort1=230301')}}" target="_blank">服装设计师</a></dd>
                            <dd><a href="{{url('/job?jobsort1=230302')}}" target="_blank">工艺师</a></dd>
                            <dd><a href="{{url('/job?jobsort1=230303')}}" target="_blank">打样/制版</a></dd>
                            <dd><a href="{{url('/job?jobsort1=230305')}}" target="_blank">质量管理</a></dd>
                            <dd><a href="{{url('/job?jobsort1=230306')}}" target="_blank">裁床</a></dd>
                            <dd><a href="{{url('/job?jobsort1=230307')}}" target="_blank">缝纫工</a></dd>
                            <dd><a href="{{url('/job?jobsort1=230403')}}" target="_blank">环评工程师</a></dd>
                        </dl>
                    </div>
                    <div class="jobLists">
                        <ul>
                            @if(count($energyCate) > 0)
                                <?php $i = 0;?>
                                @foreach($energyCate as $k =>$v)
                                    @if($i < 8)
                                        <li>
                                            <p class="p1">
                                                <a href="{{$v->joburl}}" target="_blank">{{$v->job_title}}</a>
                                                @if($v->urgent==1)<i class="one status"></i>@endif
                                                <span>{{$v->money}}</span>
                                            </p>
                                            <p class="p2">
                                                <span>{{$v->location1}}</span>
                                                <a href="{{$v->comurl}}"  target="_blank">{{$v->company_name}}</a>
                                            </p>
                                        </li>
                                    @endif
                                    <?php $i++;?>
                                @endforeach
                            @else
                                <li class="noJob">您还没有添加这个类别急招职位!</li>
                            @endif
                        </ul>
                    </div>
                </div>
            </div>
            
            {{--底部长短广告条--}}
            <div class="bottomAdv">
                @if(count($half) > 0)
                    <ul class="advHalf">
                        @foreach($half as $k=>$v)
                            <li @if($k % 2 != 0)class="noMarginRight"@endif>
                                <a  href="{{$v->ad_url}}"  target="_blank">
                                    <img src="{{$v->pic_url}}" alt="{{$v->title}}" width="490" height="80">
                                </a>
                            </li>
                        @endforeach
                    </ul>
                @endif
                <ul class="advHalfShort hide">
                    <li>
                        <a  href="javascript:void(0)">
                            <img src="" alt="" width="235" height="80">
                        </a>
                    </li>
                    <li>
                        <a  href="javascript:void(0)">
                            <img src="" alt="" width="235" height="80">
                        </a>
                    </li>
                    <li>
                        <a  href="javascript:void(0)">
                            <img src="" alt="" width="235" height="80">
                        </a>
                    </li>
                    <li class="noMarginRight">
                        <a  href="javascript:void(0)">
                            <img src="" alt="" width="235" height="80">
                        </a>
                    </li>
                </ul>
            </div>
            {{--底部长短广告条结束--}}

            {{--职场资讯--}}
            <div class="news">
                <h2><span>职场资讯</span><a href="{{url('/news')}}">更多</a></h2>
                <ul class="newsLeft">
                    <li>
                        <div class="left">
                            <img src="http://demo.15hr.com/upload/newsimg/201703/1489826325turck.jpg" alt="" width="215" height="140">
                        </div>
                        <div class="right">
                            <a class="title" href="{{url('/newsinfo_90.html')}}" target="_blank">台州科技职业学院2017年公开招聘人员公告</a>
                            <a href="{{url('/newsinfo_90.html')}}" target="_blank">根据《事业单位人
                                事管理条例》（国务院令第652号）和《台州市事业单位公开招聘人员实施办法》（台政...</a>
                            <div class="status">
                                <span class="updateDate">2017-03-18</span>
                                <span>阅读量：15</span>
                            </div>
                        </div>
                    </li>
                    <li class="marginTop">
                        <div class="left">
                            <img src="http://demo.15hr.com/upload/newsimg/201703/1489826297jqhc0.jpg" alt="" width="215" height="140">
                        </div>
                        <div class="right">
                            <a class="title" href="{{url('/newsinfo_96.html')}}" target="_blank">赣州人事人才网测试文章</a>
                            <a href="{{url('/newsinfo_96.html')}}" target="_blank">企业管理的成败甚
                                至取决于对任何一个细节的严格“把关”：如何层层筛选每一个进来的员工，考察他们的...</a>
                            <div class="status">
                                <span class="updateDate">2017-03-18</span>
                                <span>阅读量：15</span>
                            </div>
                        </div>
                    </li>
                </ul>
                <ul class="newsRight">
                    <li>
                        <a href="{{url('/newsinfo_95.html')}}" target="_blank">
                            <span class="top">1</span><span class="cont">先想好这5点，再去找工作事半功倍！</span>
                        </a>
                    </li>
                    <li>
                        <a href="{{url('/newsinfo_105.html')}}" target="_blank">
                            <span class="num">2</span><span class="cont">把人才当成客户，HR如何成为“员工体验架构师”</span>
                        </a>
                    </li>
                </ul>
            </div>
            {{--职场资讯结束--}}

            {{--友情链接--}}
            <div class="links">
                <h2><span>友情链接</span></h2>
                <ul>
                    @if(count($links) > 0)
                    @foreach($links as $v)
                        <li><a href="{{$v->url}}" target="_blank">{{$v->link_name}}</a></li>
                    @endforeach
                    @else
                        <li class="noLink">您还没有添加友情链接...</li>
                    @endif
                </ul>
            </div>
            {{--友情链接结束--}}
        </div>
    </div>
    {{--主要内容--}}
    <?php
    ?>
@endsection
{{--首页js--}}
@section('js')
    @parent
    <script type="text/javascript" src="{{'/default/js/jquery/jquery.select.js'}}"></script>
    <script type="text/javascript" src="{{'/vendor/org/layer/layer.js'}}"></script>
    <script type="text/javascript" src="{{'/default/js/jquery/jquery.form.js'}}"></script>
    <script type="text/javascript" src="{{'/vendor/swiper/swiper2.7.6.min.js'}}"></script>
    <script type="text/javascript" src="{{asset('/new/js/index/index.js')}}"></script>
    <script>
        var welcomeUrl = "{{ url('/personal/welcome') }}";
        var companyWelcomeUrl = "{{ url('/company/welcome') }}";
        var _token = "{{csrf_token()}}";
        var siteArea = {!!Site::getCity()->toJson()!!};

        $(function(){
            //全部分类列表鼠标移上事件
            $('.mainTop .categories').on('mouseenter.ddEnter','dd',function(){
                var index = $(this).index();
                $('.mainTop .cateList').removeClass('hide');
                $('.mainTop .cateList .childCate').addClass('hide').eq(index - 1).removeClass('hide')
                        .on('mouseleave.childCateLeave',function(){
                            $(this).addClass('hide').off('.childCateLeave').parent().addClass('hide');
                });
                //删除绑定事件
                $(this).off('.ddEnter');
            });
            //全部分类列表鼠标移开事件
            $('.mainTop .categories').on('mouseleave.ddLeave','dd',function(){
                var index = $(this).index();
                $('.mainTop .cateList').addClass('hide');
                $('.mainTop .cateList .childCate').addClass('hide');
                $('.mainTop .cateList .childCate').addClass('hide').eq(index - 1)
                        .on('mouseenter.childCateEnter',function(){
                            $(this).removeClass('hide').off('.childCateEnter').parent().removeClass('hide');
                });
                $(this).off('.ddLeave');
            });

            //登录框中登录对象切换
            $('.login .loginSwitch').on('click','a',function(){
                var $that = $(this);
                var data = $that.attr('data-a-text');
                $that.addClass('active').siblings().removeClass('active');
                if(data == 'personal'){
                    $('.login .' + data).removeClass('hide').next().addClass('hide');
                }else if(data == 'company'){
                    $('.login .' + data).removeClass('hide').prev().addClass('hide');
                }
            });

            //广告轮播图
            if($('.banner .swiper-container .swiper-slide').length > 1){
                var mySwiper = new Swiper('.mainTop .banner .swiper-container',{
                    autoplay : 3000,//可选选项，自动滑动
                    loop : true,//可选选项，开启循环
                    noSwiping: true, //可选选项，禁止点击滑动
                    paginationClickable :true //可选选项，开启分页器点击功能
                });
                $('.banner .swiper-slide').mouseenter(function(){
                    mySwiper.stopAutoplay();
                    $(this).mouseleave(function(){
                        mySwiper.startAutoplay();
                    });
                });
                $('.banner .play-mid-btn').mouseenter(function(){
                    mySwiper.stopAutoplay();
                    $(this).click(function(){
                        if($(this).hasClass('play-mid-BL')){
                            mySwiper.swipePrev();
                        }else{
                            mySwiper.swipeNext();
                        }
                    });
                    $(this).mouseleave(function(){
                        mySwiper.startAutoplay();
                    });
                });
            }

            //图片切换事件
            $('.mainTop .banner .brand').find('a').each(function(index){
                var oitem = $(this).find('.brand_info');
                movement($(this),200,oitem);

                //图片切换函数
                function movement(othis,otime,oitem){
                    othis.bind("mouseenter mouseleave",function(e) {
                        var w = othis.width();
                        var h = othis.height();
                        var x = (e.pageX - this.offsetLeft - (w / 2)) * (w > h ? (h / w) : 1);
                        var y = (e.pageY - this.offsetTop - (h / 2)) * (h > w ? (w / h) : 1);
                        //direction的值为“0,1,2,3”分别对应着“上，右，下，左”
                        var direction = Math.round((((Math.atan2(y, x) * (180 / Math.PI)) + 180) / 90) + 3) % 4;
                        if(e.type == 'mouseenter'){
                            switch(direction){
                                case 0 : oitem.css({'left':'0', 'top':'-100%' }); break;
                                case 1 : oitem.css({'left':'100%', 'top':'0' }); break;
                                case 2 : oitem.css({'left':'0', 'top':'100%' }); break;
                                case 3 : oitem.css({'left':'-100%', 'top':'0' }); break;
                            }
                            oitem.stop().animate({'left':'0', 'top':'0' },otime);
                        }else{
                            switch(direction){
                                case 0 : oitem.stop().animate({'left':'0', 'top':'-100%' },otime); break;
                                case 1 : oitem.stop().animate({'left':'100%', 'top':'0' },otime); break;
                                case 2 : oitem.stop().animate({'left':'0', 'top':'100%' },otime); break;
                                case 3 : oitem.stop().animate({'left':'-100%', 'top':'0' },otime); break;
                            }
                        }
                    });
                }
            });
        });
    </script>
@endsection